  :root {
            --primary-color: #6c5ce7;
            --secondary-color: #a29bfe;
            --accent-color: #fd79a8;
            --dark-color: #2d3436;
            --light-color: #f5f6fa;
            --success-color: #00b894;
            --warning-color: #fdcb6e;
            --danger-color: #d63031;
            --glow-effect: 0 0 15px rgba(108, 92, 231, 0.5);
        }

        body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            background-color: #121212;
            color: #e0e0e0;
            transition: all 0.3s ease;
        }
        
        /* Light mode overrides */
        body.light-mode {
            background-color: #fff;
            color: #222;
        }
        body.light-mode .dashboard-widget,
        body.light-mode .quiz-card,
        body.light-mode .access-tile,
        body.light-mode .timeline-content {
            background: #fff;
            color: #222;
            border-color: #eee;
        }

        body.light-mode .dashboard-header,
        body.light-mode .widget-header {
            border-bottom: 1px solid #eee;
        }

        body.light-mode .profile-avatar {
            color: #fff;
            background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
        }

        body.light-mode .auth-badge {
            background-color: var(--light-color);
            color: var(--primary-color);
        }

        body.light-mode .auth-badge.authenticated {
            background-color: var(--success-color);
            color: #fff;
        }

        body.light-mode .purchase-icon {
            background: rgba(108, 92, 231, 0.08);
            color: var(--primary-color);
        }

        body.light-mode .purchase-actions button {
            background: rgba(108, 92, 231, 0.08);
            color: var(--primary-color);
        }

        body.light-mode .purchase-actions button:hover {
            background: var(--primary-color);
            color: #fff;
        }

        body.light-mode .option-icon {
            background: rgba(108, 92, 231, 0.08);
            color: var(--primary-color);
        }

        body.light-mode .settings-option:hover {
            color: var(--primary-color);
        }

        body.light-mode .empty-state {
            color: var(--primary-color);
        }

        body.light-mode .empty-state i {
            opacity: 0.4;
        }

        body.light-mode .timeline-dot {
            background: var(--primary-color);
        }

        body.light-mode .timeline-dot::after {
            background: #fff;
        }

        body.light-mode .quiz-action {
            background: var(--primary-color);
            color: #fff;
        }

        body.light-mode .quiz-action:hover {
            background: var(--accent-color);
        }

        body.light-mode .toggle-btn {
            background: var(--primary-color);
            color: #fff;
        }

        body.light-mode .dashboard-widget {
            box-shadow: 0 4px 20px rgba(44, 62, 80, 0.07);
        }

        /* Additional overrides for true inversion */
        body.light-mode .dashboard-widget,
        body.light-mode .quiz-card,
        body.light-mode .access-tile,
        body.light-mode .timeline-content,
        body.light-mode .purchase-item,
        body.light-mode .settings-option,
        body.light-mode .quiz-meta,
        body.light-mode .timeline-date,
        body.light-mode .timeline-text,
        body.light-mode .purchase-details p,
        body.light-mode .widget-title,
        body.light-mode .widget-icon,
        body.light-mode .option-arrow {
            color: #222 !important;
            background: #fff !important;
            border-color: #eee !important;
        }

        body.light-mode .purchase-actions button,
        body.light-mode .quiz-action {
            background: #f5f6fa !important;
            color: var(--primary-color) !important;
        }

        body.light-mode .purchase-actions button:hover,
        body.light-mode .quiz-action:hover {
            background: var(--primary-color) !important;
            color: #fff !important;
        }

        body.light-mode .dashboard-header,
        body.light-mode .widget-header {
            background: #fff !important;
            color: #222 !important;
            border-bottom: 1px solid #eee !important;
        }

        body.light-mode .profile-avatar {
            color: #fff !important;
        }

        body.light-mode .timeline-dot {
            background: var(--primary-color) !important;
        }

        body.light-mode .timeline-dot::after {
            background: #fff !important;
        }

        body.light-mode .option-icon {
            background: #f5f6fa !important;
            color: var(--primary-color) !important;
        }

        body.light-mode .settings-option:last-child {
            color: var(--danger-color) !important;
        }

        body.light-mode .settings-option:last-child .option-icon {
            background: rgba(214, 48, 49, 0.1) !important;
            color: var(--danger-color) !important;
        }
        .dashboard-container {
            max-width: 1400px;
            margin: 0 auto;
            padding: 20px;
        }

/* Dark mode for Change Password Modal */
#changePasswordModal .modal-content {
    background: rgba(30, 30, 40, 0.85);
    border-radius: 18px;
    box-shadow: 0 8px 40px 0 rgba(80, 80, 180, 0.18), 0 1.5px 8px rgba(108,92,231,0.12);
    border: 1.5px solid rgba(108, 92, 231, 0.18);
    backdrop-filter: blur(18px);
    color: #e0e0e0;
    transition: background 0.3s, color 0.3s;
}
#changePasswordModal .modal-header,
#changePasswordModal .modal-footer {
    border: none;
    background: transparent;
}
#changePasswordModal .modal-title {
    font-weight: 700;
    letter-spacing: 1px;
    color: var(--primary-color);
    text-shadow: 0 2px 12px var(--primary-color), 0 1px 0 #fff2;
}
#changePasswordModal .btn-close {
    filter: invert(1);
}
#changePasswordModal .form-label {
    color: #fff;
}
#changePasswordModal .form-control {
    background: rgba(40, 40, 60, 0.7);
    color: #fff;
    border: 1px solid var(--primary-color);
}
#changePasswordModal .btn-primary {
    background: var(--primary-color);
    border: none;
}
#changePasswordModal .btn-primary:hover {
    background: var(--accent-color);
}

/* Light mode overrides for Change Password Modal */
body.light-mode #changePasswordModal .modal-content {
    background: rgba(255,255,255,0.95);
    color: #222;
    border: 1.5px solid #eee;
}
body.light-mode #changePasswordModal .modal-title {
    color: var(--primary-color);
    text-shadow: none;
}
body.light-mode #changePasswordModal .btn-close {
    filter: none;
}
body.light-mode #changePasswordModal .form-label {
    color: #222;
}
body.light-mode #changePasswordModal .form-control {
    background: #fff;
    color: #222;
    border: 1px solid var(--primary-color);
}
body.light-mode #changePasswordModal .btn-primary {
    background: var(--primary-color);
    color: #fff;
}
body.light-mode #changePasswordModal .btn-primary:hover {
    background: var(--accent-color);
}
        /* Header Styles */
        .dashboard-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 20px 0;
            border-bottom: 1px solid rgba(255, 255, 255, 0.1);
            margin-bottom: 30px;
        }

        .user-profile {
            display: flex;
            align-items: center;
            gap: 15px;
        }

        .profile-avatar {
            width: 60px;
            height: 60px;
            border-radius: 50%;
            background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-size: 24px;
            font-weight: bold;
            position: relative;
            overflow: hidden;
        }

        .profile-avatar::after {
            content: '';
            position: absolute;
            top: -50%;
            left: -50%;
            width: 200%;
            height: 200%;
            background: linear-gradient(
                to bottom right,
                rgba(255, 255, 255, 0.3),
                rgba(255, 255, 255, 0)
            );
            transform: rotate(30deg);
            animation: shine 3s infinite;
        }

        @keyframes shine {
            0% { transform: translateX(-100%) rotate(30deg); }
            100% { transform: translateX(100%) rotate(30deg); }
        }

        .user-info h2 {
            margin: 0;
            font-size: 1.5rem;
            font-weight: 600;
        }

        .user-info p {
            margin: 5px 0 0;
            color: var(--secondary-color);
            font-size: 0.9rem;
        }

        .auth-status {
            display: flex;
            align-items: center;
            gap: 10px;
        }

        .auth-badge {
            padding: 5px 10px;
            border-radius: 20px;
            font-size: 0.8rem;
            font-weight: 600;
            background-color: var(--dark-color);
            color: var(--secondary-color);
        }

        .auth-badge.authenticated {
            background-color: var(--success-color);
            color: white;
        }

        /* Main Dashboard Grid */
        .dashboard-grid {
            display: grid;
            grid-template-columns: repeat(12, 1fr);
            gap: 20px;
        }

        /* Widget Styles */
        .dashboard-widget {
            background: rgba(30, 30, 30, 0.7);
            border-radius: 12px;
            padding: 20px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
            backdrop-filter: blur(10px);
            border: 1px solid rgba(255, 255, 255, 0.05);
            transition: all 0.3s ease;
            position: relative;
            overflow: hidden;
        }

        .dashboard-widget:hover {
            transform: translateY(-5px);
            box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3), var(--glow-effect);
        }

        .widget-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 15px;
            padding-bottom: 10px;
            border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        }

        .widget-title {
            margin: 0;
            font-size: 1.2rem;
            font-weight: 600;
            color: var(--secondary-color);
        }

        .widget-icon {
            font-size: 1.5rem;
            color: var(--primary-color);
        }

        /* Quick Access Tiles */
        .quick-access {
            grid-column: span 3;
        }

        .quick-access-grid {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 15px;
        }

        .access-tile {
            background: rgba(40, 40, 40, 0.7);
            border-radius: 10px;
            padding: 15px;
            text-align: center;
            cursor: pointer;
            transition: all 0.3s ease;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            min-height: 100px;
            border: 1px solid rgba(108, 92, 231, 0.1);
        }

        .access-tile:hover {
            background: rgba(108, 92, 231, 0.1);
            border-color: var(--primary-color);
            transform: scale(1.03);
        }

        .access-tile i {
            font-size: 1.8rem;
            margin-bottom: 10px;
            color: var(--primary-color);
        }

        .access-tile h3 {
            margin: 0;
            font-size: 0.9rem;
            font-weight: 500;
        }
/* Responsive Quick Access Tiles */
@media (max-width: 992px) {
    .quick-access-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 576px) {
    .quick-access-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    .access-tile {
        min-height: 70px;
        position: relative;
        text-align: left;
        padding: 12px;
    }
    .access-tile i {
        margin-bottom: 0;
        margin-right: 12px;
        font-size: 1.5rem;
    }
    .access-tile h3 {
        font-size: 1rem;
    }
}
        /* Purchases Widget */
        .purchases-widget {
            grid-column: span 6;
        }

        .purchase-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 12px 0;
            border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        }

        .purchase-item:last-child {
            border-bottom: none;
        }

        .purchase-info {
            display: flex;
            align-items: center;
            gap: 15px;
        }

        .purchase-icon {
            width: 40px;
            height: 40px;
            border-radius: 8px;
            background: rgba(108, 92, 231, 0.2);
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--primary-color);
        }

        .purchase-details h4 {
            margin: 0;
            font-size: 1rem;
            font-weight: 500;
        }

        .purchase-details p {
            margin: 5px 0 0;
            font-size: 0.8rem;
            color: var(--secondary-color);
        }

        .purchase-actions button {
            background: rgba(108, 92, 231, 0.1);
            border: none;
            color: var(--primary-color);
            padding: 6px 12px;
            border-radius: 6px;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .purchase-actions button:hover {
            background: var(--primary-color);
            color: white;
        }
        /*invoices-widget*/
        .invoices-widget {
            grid-column: span 6;
        }

        .invoice-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 12px 0;
            border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        }

        .invoice-item:last-child {
            border-bottom: none;
        }

        .invoice-info {
            display: flex;
            align-items: center;
            gap: 15px;
        }

        .invoice-icon {
            width: 40px;
            height: 40px;
            border-radius: 8px;
            background: rgba(108, 92, 231, 0.2);
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--primary-color);
        }

        .invoice-details h4 {
            margin: 0;
            font-size: 1rem;
            font-weight: 500;
        }

        .invoice-details p {
            margin: 5px 0 0;
            font-size: 0.8rem;
            color: var(--secondary-color);
        }

        .invoice-actions button {
            background: rgba(108, 92, 231, 0.1);
            border: none;
            color: var(--primary-color);
            padding: 6px 12px;
            border-radius: 6px;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .invoice-actions button:hover {
            background: var(--primary-color);
            color: white;
        }
        /*credentials-widget*/
        .credentials-widget {
            grid-column: span 6;
        }

        .credentials-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 12px 0;
            border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        }

        .credentials-item:last-child {
            border-bottom: none;
        }

        .credentials-info {
            display: flex;
            align-items: center;
            gap: 15px;
        }

        .credentials-icon {
            width: 40px;
            height: 40px;
            border-radius: 8px;
            background: rgba(108, 92, 231, 0.2);
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--primary-color);
        }

        .credentials-details h4 {
            margin: 0;
            font-size: 1rem;
            font-weight: 500;
        }

        .credentials-details p {
            margin: 5px 0 0;
            font-size: 0.8rem;
            color: var(--secondary-color);
        }

        .crendentials-actions button {
            background: rgba(108, 92, 231, 0.1);
            border: none;
            color: var(--primary-color);
            padding: 6px 12px;
            border-radius: 6px;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .credentials-actions button:hover {
            background: var(--primary-color);
            color: white;
        }
        /*quizzes-widget*/
        .quizzes-widget {
            grid-column: span 6;
        }

        .quizzes-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 12px 0;
            border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        }

        .quizzes-item:last-child {
            border-bottom: none;
        }

        .quizzes-info {
            display: flex;
            align-items: center;
            gap: 15px;
        }

        .quizzes-icon {
            width: 40px;
            height: 40px;
            border-radius: 8px;
            background: rgba(108, 92, 231, 0.2);
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--primary-color);
        }

        .quizzes-details h4 {
            margin: 0;
            font-size: 1rem;
            font-weight: 500;
        }

        .quizzes-details p {
            margin: 5px 0 0;
            font-size: 0.8rem;
            color: var(--secondary-color);
        }

        .quizzes-actions button {
            background: rgba(108, 92, 231, 0.1);
            border: none;
            color: var(--primary-color);
            padding: 6px 12px;
            border-radius: 6px;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .quizzes-actions button:hover {
            background: var(--primary-color);
            color: white;
        }
/*______________________________________________*/


        .empty-state {
            text-align: center;
            padding: 30px 0;
            color: var(--secondary-color);
        }

        .empty-state i {
            font-size: 2.5rem;
            margin-bottom: 15px;
            opacity: 0.5;
        }

        .empty-state h3 {
            margin: 0 0 10px;
            font-weight: 500;
        }

        /* Timeline Widget */
        .timeline-widget {
            grid-column: span 3;
        }

        .timeline-item {
            position: relative;
            padding-left: 30px;
            margin-bottom: 20px;
        }

        .timeline-item:last-child {
            margin-bottom: 0;
        }

        .timeline-item::before {
            content: '';
            position: absolute;
            left: 7px;
            top: 0;
            height: 100%;
            width: 2px;
            background: var(--primary-color);
        }

        .timeline-dot {
            position: absolute;
            left: 0;
            top: 5px;
            width: 16px;
            height: 16px;
            border-radius: 50%;
            background: var(--primary-color);
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 1;
        }

        .timeline-dot::after {
            content: '';
            position: absolute;
            width: 8px;
            height: 8px;
            border-radius: 50%;
            background: white;
        }

        .timeline-content {
            background: rgba(40, 40, 40, 0.5);
            border-radius: 8px;
            padding: 12px;
        }

        .timeline-date {
            font-size: 0.7rem;
            color: var(--secondary-color);
            margin-bottom: 5px;
        }

        .timeline-text {
            font-size: 0.9rem;
            margin: 0;
        }


        /* Account Settings */
        .settings-widget {
            grid-column: span 3;
        }

        .settings-option {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 12px 0;
            border-bottom: 1px solid rgba(255, 255, 255, 0.05);
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .settings-option:hover {
            color: var(--primary-color);
        }

        .settings-option:last-child {
            border-bottom: none;
        }

        .option-icon {
            width: 30px;
            height: 30px;
            border-radius: 50%;
            background: rgba(108, 92, 231, 0.1);
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--primary-color);
        }

        .option-text {
            flex-grow: 1;
            margin-left: 15px;
        }

        .option-arrow {
            color: var(--secondary-color);
        }

        /* Dark Mode Toggle */
        .dark-mode-toggle {
            position: fixed;
            bottom: 20px;
            right: 20px;
            z-index: 1000;
        }

        .toggle-btn {
            width: 50px;
            height: 50px;
            border-radius: 50%;
            background: var(--primary-color);
            color: white;
            border: none;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            box-shadow: 0 4px 15px rgba(108, 92, 231, 0.3);
            transition: all 0.3s ease;
        }

        .toggle-btn:hover {
            transform: scale(1.1);
            box-shadow: 0 6px 20px rgba(108, 92, 231, 0.4);
        }

        /* Responsive Adjustments */
        @media (max-width: 1200px) {
            .quick-access {
                grid-column: span 4;
            }
            .purchases-widget {
                grid-column: span 8;
            }
            .quiz-widget {
                grid-column: span 12;
            }
            .timeline-widget {
                grid-column: span 4;
            }
            .settings-widget {
                grid-column: span 4;
            }
        }

        @media (max-width: 992px) {
            .dashboard-grid {
                grid-template-columns: repeat(1, 1fr);
            }
            .quick-access, .purchases-widget, 
            .quiz-widget, .timeline-widget, 
            .settings-widget {
                grid-column: span 1;
            }
            .quick-access-grid {
                grid-template-columns: repeat(4, 1fr);
            }
        }

        @media (max-width: 768px) {
            .quick-access-grid {
                grid-template-columns: repeat(2, 1fr);
            }
            .dashboard-header {
                flex-direction: column;
                align-items: flex-start;
                gap: 15px;
            }
            .auth-status {
                width: 100%;
                justify-content: space-between;
            }
        }
   .quiz-image {
  max-width: 300px;
  height: auto;
  border-radius: 8px;
}

  .favorites {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-top: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.favorite-control, .bookmark-control, .share-control {
    margin-bottom: 15px;
}

.favorite-toggle, .bookmark-toggle {
    display: none;
}

.favorite-label, .bookmark-label, .share-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 6px;
    transition: all 0.2s;
    background: #fff;
    border: 1px solid #ddd;
}

.favorite-label:hover, .bookmark-label:hover, .share-btn:hover {
    background: #f0f0f0;
}

.favorite-toggle:checked + .favorite-label,
.bookmark-toggle:checked + .bookmark-label {
    background: #e6f7ff;
    border-color: #91d5ff;
}

.bookmark-notes {
    margin-top: 10px;
}

.bookmark-notes textarea {
    width: 100%;
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ddd;
    resize: vertical;
}

.save-bookmark-btn {
    margin-top: 8px;
    padding: 6px 12px;
    background: #09c083;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.save-bookmark-btn:hover {
    background: #07a873;
}
        /* Animations */
        @keyframes fadeIn {
            from { opacity: 0; transform: translateY(20px); }
            to { opacity: 1; transform: translateY(0); }
        }

        .dashboard-widget {
            animation: fadeIn 0.5s ease forwards;
        }

        .dashboard-widget:nth-child(1) { animation-delay: 0.1s; }
        .dashboard-widget:nth-child(2) { animation-delay: 0.2s; }
        .dashboard-widget:nth-child(3) { animation-delay: 0.3s; }
        .dashboard-widget:nth-child(4) { animation-delay: 0.4s; }
        .dashboard-widget:nth-child(5) { animation-delay: 0.5s; }
        .dashboard-widget:nth-child(6) { animation-delay: 0.6s; }